package com.timo.rabbitmq.handler;

import com.rabbitmq.client.Channel;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @Description: 类用途：
 * @Author: Timo
 * @Date: 2019/7/25 15:15
 */
@Slf4j
@Component
public class DirectHandler {


    @RabbitListener(queues = "hello.direct.queue")
    public void helloDirectListener(String msg, Message message, Channel channel) {
        log.info("direct :{}",msg);
    }

}
